package com.kedou.sdk.params;

import android.os.Parcel;
import android.os.Parcelable;

import com.google.gson.annotations.SerializedName;
import com.kedou.sdk.params.bean.PayChannel;
import com.kedou.sdk.params.bean.PayChannelPlatCoin;
import com.kedou.sdk.params.bean.PlatCoinCurrency;
import com.kedou.sdk.params.bean.PlatCoinRate;

import java.util.List;

/**
 * Created by Administrator on 2017/6/9 0009.
 */

public class PlatFormCoinResponseParams extends ResponseParams<PlatFormCoinResponseParams.CreateOrderResponseData> {

    public static class CreateOrderResponseData implements Parcelable {

        private PayChannelPlatCoin CurrencyUser;
        private PlatCoinRate Proportion;
        private List<PlatCoinCurrency> CurrencyList;
        @SerializedName("PayList")
        private List<PayChannel> PayList;

        public PayChannelPlatCoin getCurrencyUser() {
            return CurrencyUser;
        }

        public void setCurrencyUser(PayChannelPlatCoin currencyUser) {
            CurrencyUser = currencyUser;
        }

        public List<PlatCoinCurrency> getCurrencyList() {
            return CurrencyList;
        }

        public void setCurrencyList(List<PlatCoinCurrency> currencyList) {
            CurrencyList = currencyList;
        }

        public List<PayChannel> getPayList() {
            return PayList;
        }

        public void setPayList(List<PayChannel> payList) {
            PayList = payList;
        }

        public PlatCoinRate getProportion() {
            return Proportion;
        }

        public void setProportion(PlatCoinRate proportion) {
            Proportion = proportion;
        }

        public CreateOrderResponseData() {
        }

        protected CreateOrderResponseData(Parcel in) {
            CurrencyUser = in.readParcelable(PayChannelPlatCoin.class.getClassLoader());
            CurrencyList = in.createTypedArrayList(PlatCoinCurrency.CREATOR);
            PayList = in.createTypedArrayList(PayChannel.CREATOR);
            Proportion =in.readParcelable(PlatCoinRate.class.getClassLoader());
        }

        public static final Creator<CreateOrderResponseData> CREATOR = new Creator<CreateOrderResponseData>() {
            @Override
            public CreateOrderResponseData createFromParcel(Parcel in) {
                return new CreateOrderResponseData(in);
            }

            @Override
            public CreateOrderResponseData[] newArray(int size) {
                return new CreateOrderResponseData[size];
            }
        };


        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeParcelable(this.CurrencyUser,flags);
            dest.writeTypedList(this.CurrencyList);
            dest.writeTypedList(this.PayList);
            dest.writeParcelable(this.Proportion,flags);

        }
    }

}
